# uncompyle6 version 3.2.3
# Python bytecode 3.6 (3379)
# Decompiled from: Python 3.6.8 |Anaconda custom (64-bit)| (default, Feb 21 2019, 18:30:04) [MSC v.1916 64 bit (AMD64)]
# Embedded file name: site-packages\gevent\__init__.py
"""
gevent is a coroutine-based Python networking library that uses greenlet
to provide a high-level synchronous API on top of libev event loop.

See http://www.gevent.org/ for the documentation.
"""
from __future__ import absolute_import
from collections import namedtuple

_version_info = namedtuple(
    "version_info", ("major", "minor", "micro", "releaselevel", "serial")
)
version_info = _version_info(1, 2, 2, "dev", 0)
__version__ = "1.2.2"
__all__ = [
    "get_hub",
    "Greenlet",
    "GreenletExit",
    "spawn",
    "spawn_later",
    "spawn_raw",
    "iwait",
    "wait",
    "killall",
    "Timeout",
    "with_timeout",
    "getcurrent",
    "sleep",
    "idle",
    "kill",
    "signal",
    "fork",
    "reinit",
]
import sys

if sys.platform == "win32":
    import socket

    del socket
from gevent.hub import get_hub, iwait, wait
from gevent.greenlet import Greenlet, joinall, killall

joinall = joinall
spawn = Greenlet.spawn
spawn_later = Greenlet.spawn_later
from gevent.timeout import Timeout, with_timeout
from gevent.hub import getcurrent, GreenletExit, spawn_raw, sleep, idle, kill, reinit

try:
    from gevent.os import fork
except ImportError:
    __all__.remove("fork")

from gevent.hub import signal as _signal_class
from gevent import signal as _signal_module


class _signal_metaclass(type):
    def __getattr__(cls, name):
        return getattr(_signal_module, name)

    def __setattr__(cls, name, value):
        setattr(_signal_module, name, value)

    def __instancecheck__(cls, instance):
        return isinstance(instance, _signal_class)

    def __dir__(cls):
        return dir(_signal_module)


class signal(object):
    """signal"""

    def __new__(cls, *args, **kwargs):
        return _signal_class(*args, **kwargs)


signal = _signal_metaclass(str("signal"), (), dict(signal.__dict__))
sys.modules["gevent.signal"] = signal
sys.modules["gevent.hub"].signal = signal
del sys


def __dependencies_for_freezing():
    from gevent import core
    from gevent import resolver_thread
    from gevent import resolver_ares
    from gevent import socket as _socket
    from gevent import threadpool
    from gevent import thread
    from gevent import threading
    from gevent import select
    from gevent import subprocess
    import pprint, traceback, signal as _signal


del __dependencies_for_freezing
